package com.heo.coder.packet;

import com.heo.coder.packet.base.BasePacket;
import com.heo.pojo.DeviceInfoEntity;
import com.heo.util.ByteHelper;
import com.heo.util.DeviceCommand;
import com.heo.util.Utils;

public class StartPacketRsp extends BasePacket{

	public StartPacketRsp() throws Exception {
		super("", 0, "", DeviceCommand.START_COMMAND_RSP, "");
	}
	
	/**
	 * 
	 * @param cmd
	 */
	public void setMsgContent(String cmd) {
		String lengthStr = ByteHelper.intToHexString(9, 2);
		setLengthStr(lengthStr);
		setBody(cmd);
		checkData();
	}
	
	@Override
	public String toString() {
		return "SocketPacket: [" + control + "] [" + START_MARKER_LENGTH_CODE + getLengthStr() + getCheck() +  getControl() + getBody()  + "]";
	}

	@Override
	public String getPacketBody() {
		return super.body;
	}

	
	
}
